﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;

namespace 枚举1
{
    //    1、编写程序，定义一个枚举类型，表示订单的状态值：新订单、已发货、已签收、已评价；
    //声明一个枚举类型表示某个订单的状态并将其值输出。
    public enum ListState
    {
        新订单,
        已发货,
        已签收,
        已评价
    }
    class Program
    {
        static void Main(string[] args)
        {
            Console.WriteLine("1.新订单 2.已发货 3.已发货 4.已签收");
            int number = -1;
            while (number != 5)
            {
            number = int.Parse(Console.ReadLine());

                switch (number)
                {
                    case 1:
                        ListState state = (ListState)number;
                        Console.WriteLine("现在的状态 "+ state);
                        Console.ReadLine();
                        break;
                    case 2:
                        ListState state2 = (ListState)number;
                        Console.WriteLine("现在的状态 "+ state2);
                        Console.ReadLine();
                        break;
                    case 3:
                        ListState state3 = (ListState)number;
                        Console.WriteLine("现在的状态 "+state3);
                        Console.ReadLine();
                        break;
                    case 4:
                        ListState state4 = (ListState)number;
                        Console.WriteLine("现在的状态 "+ state4);
                        Console.ReadLine();
                        break;
                    default:
                        break;
                }
            }
            Console.ReadKey();
        }
    }
}
